let marbleRaceLevel9_5 = {
	name: 'Game 9 Level 5',
	id: '9_5',
	type: 'value',
	valueBonus: 0,
	scoreBonus: 5,
	valueThreshold: 0,
	minPass: 1,
	objects: [
		// Portals
		{
			type: 'object',
			shape: 'rect',
			color: '@a',
			toPortal: 'a',
			x: 140,
			y: 540 - 10,
			width: 120,
			height: 20,
			valueMultiply: .5
		},
		{
			type: 'text',
			content: '÷2',
			color: '@foreground',
			x: 140,
			y: 540 - 10
		},
		{
			type: 'object',
			shape: 'rect',
			color: '@a',
			toPortal: 'a',
			x: 260,
			y: 540 - 10,
			width: 120,
			height: 20,
			valueBonus: -3
		},
		{
			type: 'text',
			content: '−3',
			color: '@foreground',
			x: 260,
			y: 540 - 10
		},
		{
			type: 'object',
			shape: 'rect',
			color: '@goal',
			toPortal: 'goal',
			isGoal: true,
			x: 340,
			y: 540 - 10,
			width: 40,
			height: 20
		},
		{
			type: 'object',
			shape: 'rect',
			color: '@a',
			toPortal: 'a',
			x: 420,
			y: 540 - 10,
			width: 120,
			height: 20,
			valueBonus:-1
		},
		{
			type: 'text',
			content: '−1',
			color: '@foreground',
			x: 420,
			y: 540 - 10
		},
		{
			type: 'object',
			shape: 'rect',
			color: '@b',
			toPortal: 'a',
			x: 540,
			y: 540 - 10,
			width: 120,
			height: 20,
			valueBonus: 5
		},
		{
			type: 'text',
			content: '+5',
			color: '@background',
			x: 540,
			y: 540 - 10
		},
		{
			type: 'object',
			shape: 'circle',
			color: '@a',
			portalID: 'a',
			x: 130,
			y: 80,
			radius: 5
		},

		// Goal portal
		{
			type: 'object',
			shape: 'circle',
			color: '@goal',
			portalID: 'goal',
			x: 700,
			y: 80,
			radius: 5
		},

		// Obstacles
		{
			type: 'object',
			shape: 'rect',
			color: '@c',
			x: 130,
			y: 450,
			width: 65,
			height: 20,
			onCollide: function (object, marbleID, engine) {
				let v = engine.getVelocity(engine.circleArray[marbleID])
				v[0] += engine.random(2, 8)
				v[1] -= 10
				engine.setVelocity(engine.circleArray[marbleID], v)
			}
		},
		{
			type: 'text',
			content: '>>>',
			color: '@foreground',
			x: 130,
			y: 450
		},

		// Borders
		{
			type: 'object',
			shape: 'rect',
			color: '@tertiary',
			x: 400,
			y: 0,
			width: 800,
			height: 120
		},
		{
			type: 'object',
			shape: 'rect',
			color: '@tertiary',
			x: 400,
			y: 600,
			width: 800,
			height: 120
		},
		{
			type: 'object',
			shape: 'rect',
			color: '@tertiary',
			x: 0,
			y: 300,
			width: 160,
			height: 600
		},
		{
			type: 'object',
			shape: 'rect',
			color: '@tertiary',
			x: 800,
			y: 300,
			width: 160,
			height: 600
		},
		{
			type: 'object',
			shape: 'rect',
			color: '@tertiary',
			x: 640,
			y: 300,
			width: 80,
			height: 600
		},

		// Marbles
		{
			type: 'marbles',
			x: 130,
			y: 80,
			launchTime: 3,
			launchRadius: 75,
			passX: 700,
			passY: 80,
			radius: 8,
			eliminatedRadius: 6,
			velocity: 5
		},
	]
}
marbleRaceLevels.push(marbleRaceLevel9_5)